<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>spring boot + web socket + 广播式</title>
</head>
<body onload="connect()">
<noscript><h2 style="color:red">貌似你的浏览器不支持websocket</h2></noscript>
<div>
	<div>
		<button id="connect" onclick="connect()">连接</button>
		<button id="disconnect" disabled="disabled" onclick="disconnect()">断开连接</button>
	</div>
	<div id="conversationDiv">
		<label>输入你的名字</label>
		<input type="text" id="name"/>
		<button id="sendName" onclick="sendName()">发送</button>
		<p id="response"></p>
	</div>
</div>
<script src="https://cdn.bootcss.com/stomp.js/2.3.3/stomp.js"></script>
<script src="https://cdn.bootcss.com/sockjs-client/1.1.4/sockjs.min.js"></script>
<script src="https://code.jquery.com/jquery-3.1.1.min.js"></script>
<script type="text/javascript" th:src="@{/js/layer.js}"></script>
</body>
</html>